# Maintainer: Olliver Schinagl <oliver@schinagl.nl>
pkgname=websocat
pkgver=1.9.0
pkgrel=0
pkgdesc="Netcat, curl and socat for WebSockets"
url="https://github.com/vi/websocat"
arch="all !s390x !riscv64" # Limited by cargo/rust
license="MIT"
makedepends="cargo openssl-dev"
options="net"
source="https://github.com/vi/websocat/archive/v$pkgver/websocat-$pkgver.tar.gz"

build() {
	cargo build --release --locked
}

check() {
	cargo test --release --locked
}

package() {
	install -D -m 0755 "target/release/websocat" -t "$pkgdir/usr/bin"
}

sha512sums="
0506b2047652c83a0f1b0df25179831cc2733392ebd208bcc09cc60eb6567cc339fde268f0d98eb0b6f00df48640a3e28d2115c7bf2b8519a9b86cb9389c7050  websocat-1.9.0.tar.gz
"
